package com.example.cxx.pojo;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

@Data
@NoArgsConstructor
@AllArgsConstructor
public class ScoreList implements Comparable<ScoreList>{
    //成绩信息
    private String year;//学年
    private String term;//学期
    private String subjectName;//课程名
    private String examType;//考试性质
    private String examTime;//考试日期
    private String scorePoint;//学分
    private String subjectType;//课程类别
    private String examScore;//考试成绩
    private String examPoint;//成绩绩点

    @Override
    public int compareTo(ScoreList o) {
        if(this.getYear().compareTo(o.getYear())!=0){
            return this.getYear().compareTo(o.getYear());
        }
        else {
            return  this.getTerm().compareTo(o.getTerm());
        }
    }
}
